export interface User {
  id: number
  name: string
  email: string
  // 其他用户属性...
}

export interface CommonResponse<T = any> {
  code: number
  data: T
  message: string
  statusText: string
}

export interface FileInfo {
  id: number
  user_id: number
  name: string
  url: string
  exts: string
  created_at: string
  updated_at: string
  ext: string
}

export interface UploadResponse extends FileInfo {
  other: {
    canDownload: boolean
    name: string
    downloadPath: string
    createUser: {
      userID: string
    }
  }
}
export interface ResourceItem extends FileInfo {
  public?: 0 | 1
  tags?: TagItem[]
}

export interface FileCourseInfo {
  id: number
  user_id: number
  category_sign: string
  type: string
  title: string
  content: string
  updated_at: string
  created_at: string
}

export interface LabelValue {
  label: string
  value: string
}
export interface AreaList {
  alias: string
  created_at: string
  en_name: string
  id: number
  updated_at: string
  zh_name: string
}

export interface HotTopicItem {
  id: number
  area_id: number | null
  word: string
  word_id: string
  zh_word: string
  score: string
  cover_image_uri: string
  created_at: string
  updated_at: string
}
export interface ToneStore {
  id: number
  user_id: number
  names: {
    en: string
    zh: string
  }
  file_id: string
  file_url: string
  is_active: number
  created_at: string
  updated_at: string
  voice_id?: string
}

export interface CloseToneStore {
  id: number
  user_id: number
  file_id: string
}

export interface ResourceQuery {
  keywords: string
  exts: string // image | video
  order_by?: string // created_at | name
  direction?: string // asc | desc
  created_at_start?: string // 创建时间开始
  created_at_end?: string // 创建时间结束
  pageNum?: number
  pageSize?: number
  public?: 0 | 1 | undefined
  tags?: string
}

export interface queryPagination {
  pageNum: number
  pageSize: number
}

export interface TagItem {
  id: number
  user_id: number
  name: string
  created_at: string
  updated_at: string
}
